import * as React from 'react'
import { observable } from 'mobx'
import { observer, inject } from 'mobx-react'
import {Link} from "react-router-dom"
import FN from '../tools/fn'


@inject('chat')
@observer
export default class Chat extends React.Component {
  constructor(props) {
    super(props)
    this.store = this.props.chat
  }
  render() {
    let test=100;
    return (
      <div>
       
        <div className="am-list">
          <div className="am-list-header">REACT 常用demo</div>
          <div className="am-list-body">
              <div className="am-list-item">
              <Link to={{
                    pathname: '/article',
                    search:`?sort=${test}`,
                    }} className="am-list-content">去文章页面</Link>
                <div className="am-list-arrow" aria-hidden="true"><span className="am-icon arrow horizontal"></span></div>
              </div>
              <div className="am-list-item">
              <Link to="/childRouter" className="am-list-content">去看子路由demo</Link>
                <div className="am-list-arrow" aria-hidden="true"><span className="am-icon arrow horizontal"></span></div>
              </div>
              <div className="am-list-item">
                <Link to="/animation" className="am-list-content">animation</Link>
                <div className="am-list-arrow" aria-hidden="true"><span className="am-icon arrow horizontal"></span></div>
              </div>
              <div className="am-list-item">
                <Link to="/list" className="am-list-content">下拉加载&&mobx</Link>
                <div className="am-list-arrow" aria-hidden="true"><span className="am-icon arrow horizontal"></span></div>
              </div>
              <div className="am-list-item">
                <Link to="/cacheRoute" className="am-list-content">缓存路由&&错误边界控制(进入详情后刷新再返回上一页)</Link>
                <div className="am-list-arrow" aria-hidden="true"><span className="am-icon arrow horizontal"></span></div>
              </div>
          </div>
        </div>
      </div>                
    )}
  }
}
